﻿using CodeSHARPer.ViewModel.Base;
using ICSharpCode.CodeCompletion;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Linq;
using System.Text;

namespace CodeSHARPer.ViewModel.Dialogs
{
    public class NewFileViewModel : DialogViewModelBase
    {
        public class NewFile
        {
            public string ImageSource { get; set; }
            public string Name { get; set; }
            public string Description { get; set; }
            public CodeScriptType NewFileType { get; set; }
        }

        List<NewFile> fileTypes;
        public List<NewFile> FileTypes
        {
            get
            {
                if (fileTypes == null)
                {
                    fileTypes = new List<NewFile>();
                    fileTypes.Add(new NewFile { Name = "C# Script", NewFileType = CodeScriptType.Snippet, Description = "A simple file that can contain multiple c# statements.", ImageSource = @"..\..\Themes\Images\App\appbar.language.csharp.png" });
                    fileTypes.Add(new NewFile { Name = "C# Program", NewFileType = CodeScriptType.Program, Description = "A simple file that has a main method and can contain custom methods and classes.", ImageSource = @"..\..\Themes\Images\App\appbar.language.csharp.png" });
                }
                return fileTypes;
            }
            set
            {
                fileTypes = value;
            }
        }

        NewFile selectedFileType;
        public NewFile SelectedFileType
        {
            get { return selectedFileType; }
            set { selectedFileType = value; }
        }
    }
}
